using CosyTrade.Core;
using CosyTrade.Network;
using DevExpress.XtraEditors;

namespace CosyTrade.UI
{
    public class MainFormBase : XtraForm, IMainForm
    {
        protected SystemStat currentSystemStat;
        protected AddinManager currentAddinManager;
        protected IRemotingPortalFactory currentPortalFactory;
        protected IStatbarController currentStatbarController;

        public void UpdateToolbarElement()
        {
            RefreshToolbarElement();
        }

        public IStatbarController GetStatbarController()
        {
            return currentStatbarController;
        }

        public SystemStat CurrentSystemStat
        {
            get { return currentSystemStat; }
        }

        public AddinManager CurrentAddinManager
        {
            get { return currentAddinManager; }
        }

        public IRemotingPortalFactory CurrentPortalFactory
        {
            get { return currentPortalFactory; }
        }

        public IStatbarController CurrentStatbarController
        {
            get { return currentStatbarController; }
        }

        protected virtual void RefreshToolbarElement()
        {
        }
    }
}